{% from 'macros/_misc.html' import render_pagination, render_user_table %}

{% extends 'layouts/base.html' %}

{% if keywords %}
    {% set page_title = _('Search results for "%(keywords)s"', keywords=keywords) %}
{% else %}
    {% set page_title = _('Keywords needed!') %}
{% endif %}

{% block body %}
    {% if pagination and pagination.pages > 0 %}
        <p>{% trans total=pagination.total, keywords=keywords %}<strong>{{ total }}</strong> found for your search "<strong>{{ keywords }}</strong>".{% endtrans %}</p>
        {{ render_user_table(pagination.items, 'zebra-striped') }}
        {{ render_pagination(pagination, 'frontend.search') }}
    {% else %}
        <p>{% trans keywords=keywords %}Sorry, Nothing found for your search "<strong>{{ keywords }}</strong>".{% endtrans %}</p>
    {% trans %}
    <p>Suggestions:</p>
    <ul>
       <li>Make sure all words are spelled correctly.</li>
       <li>Try different keywords.</li>
       <li>Try more general keywords.</li>
    </ul>
    {% endtrans %}
    {% endif %}
{% endblock %}
